package com.loubii.sunshineSchool.pojo;

import org.greenrobot.greendao.annotation.Entity;
import org.greenrobot.greendao.annotation.Generated;
import org.greenrobot.greendao.annotation.Id;

import java.util.Date;

@Entity
public class AccountModel implements Comparable<AccountModel>{

    @Id(autoincrement = true)
    private Long id; //用户唯一标识


    private float count;
    private int outIntype;
    private String detailType;
    private int picRes;
    private Date time;

    private String note;

    private String remark;
    public String getNote() {
        return this.note;
    }
    public void setNote(String note) {
        this.note = note;
    }
    public String getDetailType() {
        return this.detailType;
    }
    public void setDetailType(String detailType) {
        this.detailType = detailType;
    }
    public int getOutIntype() {
        return this.outIntype;
    }
    public void setOutIntype(int outIntype) {
        this.outIntype = outIntype;
    }
    public float getCount() {
        return this.count;
    }
    public void setCount(float count) {
        this.count = count;
    }
    public Long getId() {
        return this.id;
    }
    public void setId(Long id) {
        this.id = id;
    }
    public String getRemark() {
        return this.remark;
    }
    public void setRemark(String remark) {
        this.remark = remark;
    }
    public void setTime(Date time) {
        this.time = time;
    }
    public Date getTime() {
        return this.time;
    }
    public int getPicRes() {
        return this.picRes;
    }
    public void setPicRes(int picRes) {
        this.picRes = picRes;
    }
    public AccountModel(Long id, float count, int outIntype, String detailType, String note, String remark) {
        this.id = id;
        this.count = count;
        this.outIntype = outIntype;
        this.detailType = detailType;
        this.note = note;
        this.remark = remark;
    }
    public AccountModel() {
    }
    @Generated(hash = 741446720)
    public AccountModel(Long id, float count, int outIntype, String detailType, int picRes, Date time,
            String note, String remark) {
        this.id = id;
        this.count = count;
        this.outIntype = outIntype;
        this.detailType = detailType;
        this.picRes = picRes;
        this.time = time;
        this.note = note;
        this.remark = remark;
    }

    @Override
    public int compareTo(AccountModel o) {
        if (this.count < o.count)
            return -1;
        else if (this.count > o.count)
            return 1;
        else
            return 0;
    }
}
